
const mongoose = require('./db')

const MedSchema=new mongoose.Schema({
    name:String,
    sum:Number,
    content:String,
    hospital:String,
})

const MedModel = mongoose.model('med', MedSchema, 'med')

const doctorSchema=new mongoose.Schema({
    id:Number,
    name:String,
    ke:String,
    duties:String,
    yi:String,
    ty:String,
    state:Boolean
})

const DoctorModel = mongoose.model('doctor', doctorSchema, 'doctor')

const haoSchema=new mongoose.Schema({
    name:String,
    ke:String,
    kai:Date,
    jie:String,
    sum:Number,
    price:Number,
    state:Boolean,
    yu:String,
    time:Date
})
const HaoModel = mongoose.model('hao', haoSchema, 'hao')



const detailSchema = new mongoose.Schema({
    classify: String,
    quality: String,
    care: String,
    grade: String,
    regiona: String,
    regionb: String,
    regionc: String,
    address: String,
    route: String,
    phone: String,
    website: String,
    introduction: String
})

const DetailModel = mongoose.model('detail', detailSchema, 'detail')



module.exports = {
    MedModel,
    DoctorModel,
    HaoModel,
    DetailModel,
}